<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="author" content="thanhansoft" />
<meta name="keywords" content="<?php echo TITLE ?> - <?php echo KEYWORD ?>" />
<meta name="description" content="<?php echo TITLE ?> - <?php echo DESCRIPTION ?>" />
<link type="text/css" rel="stylesheet" href="<?php echo TEMPLATE ?>/css/dosvn.css" />
<link rel="SHORTCUT ICON" href="<?php echo TEMPLATE ?>/images/favicon.ico" type="image/x-icon" />
<link rel="icon" href="<?php echo TEMPLATE ?>/images/favicon.ico" type="image/gif" />
<title><?php echo TITLE ?></title>
<?php
	if(isset($css)){
		foreach($css as $value){
			echo $value;
		}
	}
?>
</head>
<body>
<div id="wapper">
	<a href="./"><img src="<?php echo TEMPLATE ?>/images/logo.png" alt="Logo" class="logo" /></a>
	<div id="header">
    	<ul>
            <li>Chào <span><?php echo $_SESSION['username']; ?></span></li>
        	<li><a href="#">Quản lý tài khoản</a></li>
            <li><a href="<?php echo PATH ?>/index/logout">Đăng xuất</a></li>
    	</ul>
    </div>
	<div class="menu-left">
		<?php $this->loadFunction($module, 1); ?>
	</div>
	<div id="content">
    	<div class="contenter">
            <?php
                if(isset($list)){
                    echo '<div style="padding:10px"><table><thead>
                			<tr>
                				<th><input onclick="javascript: select_switch(this.checked);" type="checkbox" name="checkall" /></th>
                				<th>Tên công việc</th>
                				<th>Người yêu cầu</th>
                				<th>Ngày tạo</th>
                				<th>Trạng thái</th>
                				<th>Thao tác</th>
                			</tr>
            		      </thead><tbody>';
                    if(count($list) > 0){
                        while (list($key, $value) = each($list)) {
                            echo '<tr>
                    				<td><input type="checkbox" name="ids[]" value="'.$value['job_id'].'" /></td>
                    				<td><b>'.$value['job_title'].'</b></td>
                    				<td>'.$value['dos_model_usernames_username'].'</td>
                    				<td>'.date("d-m-Y H:i:s", strtotime($value['create_date'])).'</td>
                    				<td>'.$value['status'].'</td>
                    				<td><a href="#" title="Chỉnh sửa">Chỉnh sửa</a></td>
                    			</tr>';
                        }
                    }else{
                        //no item
                        echo '<tr><td colspan="6">Chưa có công việc, bạn đang rãnh rỗi</td></tr>';
                    }
                    echo '</tbody></table></div>';
                }
            ?>
			<?php $this->loadFunction($module, 2); ?>
		</div>
        <div id="footer"><div>Copyright &copy; 2011 by Dos.vn. All rights reserved</div></div>
    </div>
</div>
</body>
</html>